package com.totoro.service;

import com.totoro.pojo.*;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * @author TOTORO
 * @date 2021/8/9 23:50
 */
public interface ReturnService {

    List<PrimaryReturn> findUserReturnList(int uid, int type, int time, int status, String startTime, String endTime);

    Integer addPrimaryReturn(PrimaryReturn primaryReturn);

    Integer updatePrimaryReturn(PrimaryReturn primaryReturn);

    Integer addPrimaryReturnImage(Integer primaryReturnId, Integer returnStatus, MultipartFile[] files,  String[] instructions, HttpServletRequest request);

    Integer deletePrimaryReturnAssignStatusImages(int prId, int status);

    Integer deletePrimaryReturnOneStatusImages(int prId, Integer[] originalImageId);

    List<PrtImages> findShallQuiltRemoveMultipleImage(int prId, Integer[] originalImageId);

    Integer updatePrimaryReturnAssignStatusImageInstructionByImageId(int piId, String instruction);

    Integer addPrimaryReturnAssignStatusInfo(ReturnStatusInfo returnStatusInfo);

    Integer addNegotiateHistory(NegotiateHistory negotiateHistory);

    Integer addNegotiateHistoryImage(int nhId, MultipartFile[] files, String[] instructions, HttpServletRequest request);

    PrimaryReturn findPrimaryReturnAllDetailByReturnOdd(String returnOdd);

    Integer updatePrimaryReturnStatusByReturnOdd(PrimaryReturn primaryReturn);

    Integer findOrderOddByPrimaryReturnId(int primaryReturnId);

    PrimaryReturn findPrimaryReturnByMarketSrId(int msrId);
}
